By Prabhav Adhikari
alias <String> = <Command>
alias p = "pwd"
An alias can be created with the same name as the core name of a command
An alias named ls could be created for the command ls -al
alias ls= "ls -al"
Multiple commands can be included in the same alias
Insert them within the same pair of quotation marks and Separate them with semicolons
alias pl = 'pwd; ls'
Aliases can even be created to call other aliases
alias l='ls -a'
alias pl='p; l'
Aliases can be used with any argument that the command can be used with
l /home/Documents
Any alias set up with it remains in effect only during the current login session
Type alias only to see a list of aliases.
Use unalias alias-name to remove an alias
A basic Calculator
In the bc environment type expressions and get their results
5*5+3*23
Use last to use last answer in your expression.
last * 2 - 1
Symbol used to provide output of one command as input to another command
Used to direct the output to a file.
Used to append the output to a file
Used to search text for patterns specified by the user
Basic Syntax:
grep <pattern> <file>To see the occurances of 'is' in a file 'Intro.txt':
grep 'is' Intro.txt
Used to check if an address is accessible
Syntax: ping <destination>
ping transmits packets to the address and checks if it is received
To restrict number of packets use ping -c <no>
Example ping -c 5 google.com
Used to provide information about the currently running processes including their process identification numbers (PIDs)
Syntax: ps
Used to kill a process.
Syntax: kill <pid>
TeleTYpewriter
There are 6 virtual consoles in Ubuntu
They can be accessed by the keyboard shortcuts
Ctrl + Alt + F1 - F7
tty 1 to 6 have text UI while 7th has Graphics UI.